package com.asset.troubleticket.service;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.asset.troubleticket.dao.EmployeeDao;
import com.asset.troubleticket.domain.Employee;

@Service
@Transactional(readOnly=false)
public class EmployeeService {
	@Autowired
	EmployeeDao employeeDao;
	
	
	@Transactional(readOnly=false)
	public void addEmployee(Employee employee) {
		employeeDao.addEmployee(employee);
	}
	
	@Transactional(readOnly=false)
	public void editEmployee(Employee employee){
		employeeDao.editEmployee(employee);
	}
	
	@Transactional(readOnly=false)
	public void deleteEmployee(Employee employee){
		employeeDao.deleteEmployee(employee);
	}
	
	@Transactional(readOnly=false)
	public Employee getById(Integer id){
		return employeeDao.getById(id);
	}



}
